package sgc.struc;

import java.util.Date;

public class Customer {

	private String company;
	private int code;
	private String name1;
	private String name2;
	private String name3;
	private String name4;
	private String address_st;
	private String address_no;
	private String address_fl;
	private String address_ap;
	private String city;
	private String state;
	private String country;
	private String postal_code;
	private String tax_id_1;
	private String tax_type_1;
	private String tax_id_2;
	private String tax_type_2;
	private Date start_date;
	private String phone;
	private String mail;

	public Customer() {
		// TODO Auto-generated constructor stub
	}

	public String getCompany() {
		return company;
	}

	public int getCode() {
		return code;
	}

	public String getName1() {
		return name1;
	}

	public String getName2() {
		return name2;
	}

	public String getName3() {
		return name3;
	}

	public String getName4() {
		return name4;
	}

	public String getAddress_st() {
		return address_st;
	}

	public String getAddress_no() {
		return address_no;
	}

	public String getAddress_fl() {
		return address_fl;
	}

	public String getAddress_ap() {
		return address_ap;
	}

	public String getCity() {
		return city;
	}

	public String getPostal_code() {
		return postal_code;
	}

	public String getTax_id_1() {
		return tax_id_1;
	}

	public String getTax_type_1() {
		return tax_type_1;
	}

	public String getTax_id_2() {
		return tax_id_2;
	}

	public String getTax_type_2() {
		return tax_type_2;
	}

	public Date getStart_date() {
		return start_date;
	}

	public String getPhone() {
		return phone;
	}

	public String getMail() {
		return mail;
	}

	public void setCompany(String company) {
		this.company = company;
	}

	public void setCode(int code) {
		this.code = code;
	}

	public void setName1(String name1) {
		this.name1 = name1;
	}

	public void setName2(String name2) {
		this.name2 = name2;
	}

	public void setName3(String name3) {
		this.name3 = name3;
	}

	public void setName4(String name4) {
		this.name4 = name4;
	}

	public void setAddress_st(String address_st) {
		this.address_st = address_st;
	}

	public void setAddress_no(String address_no) {
		this.address_no = address_no;
	}

	public void setAddress_fl(String address_fl) {
		this.address_fl = address_fl;
	}

	public void setAddress_ap(String address_ap) {
		this.address_ap = address_ap;
	}

	public void setCity(String city) {
		this.city = city;
	}

	public void setPostal_code(String postal_code) {
		this.postal_code = postal_code;
	}

	public void setTax_id_1(String tax_id_1) {
		this.tax_id_1 = tax_id_1;
	}

	public void setTax_type_1(String tax_type_1) {
		this.tax_type_1 = tax_type_1;
	}

	public void setTax_id_2(String tax_id_2) {
		this.tax_id_2 = tax_id_2;
	}

	public void setTax_type_2(String tax_type_2) {
		this.tax_type_2 = tax_type_2;
	}

	public void setStart_date(Date start_date) {
		this.start_date = start_date;
	}

	public void setPhone(String phone) {
		this.phone = phone;
	}

	public void setMail(String mail) {
		this.mail = mail;
	}

	public String getState() {
		return state;
	}

	public String getCountry() {
		return country;
	}

	public void setState(String state) {
		this.state = state;
	}

	public void setCountry(String country) {
		this.country = country;
	}

	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result
				+ ((address_ap == null) ? 0 : address_ap.hashCode());
		result = prime * result
				+ ((address_fl == null) ? 0 : address_fl.hashCode());
		result = prime * result
				+ ((address_no == null) ? 0 : address_no.hashCode());
		result = prime * result
				+ ((address_st == null) ? 0 : address_st.hashCode());
		result = prime * result + ((city == null) ? 0 : city.hashCode());
		result = prime * result + code;
		result = prime * result + ((company == null) ? 0 : company.hashCode());
		result = prime * result + ((country == null) ? 0 : country.hashCode());
		result = prime * result + ((mail == null) ? 0 : mail.hashCode());
		result = prime * result + ((name1 == null) ? 0 : name1.hashCode());
		result = prime * result + ((name2 == null) ? 0 : name2.hashCode());
		result = prime * result + ((name3 == null) ? 0 : name3.hashCode());
		result = prime * result + ((name4 == null) ? 0 : name4.hashCode());
		result = prime * result + ((phone == null) ? 0 : phone.hashCode());
		result = prime * result
				+ ((postal_code == null) ? 0 : postal_code.hashCode());
		result = prime * result
				+ ((start_date == null) ? 0 : start_date.hashCode());
		result = prime * result + ((state == null) ? 0 : state.hashCode());
		result = prime * result
				+ ((tax_id_1 == null) ? 0 : tax_id_1.hashCode());
		result = prime * result
				+ ((tax_id_2 == null) ? 0 : tax_id_2.hashCode());
		result = prime * result
				+ ((tax_type_1 == null) ? 0 : tax_type_1.hashCode());
		result = prime * result
				+ ((tax_type_2 == null) ? 0 : tax_type_2.hashCode());
		return result;
	}

	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		Customer other = (Customer) obj;
		if (address_ap == null) {
			if (other.address_ap != null)
				return false;
		} else if (!address_ap.equals(other.address_ap))
			return false;
		if (address_fl == null) {
			if (other.address_fl != null)
				return false;
		} else if (!address_fl.equals(other.address_fl))
			return false;
		if (address_no == null) {
			if (other.address_no != null)
				return false;
		} else if (!address_no.equals(other.address_no))
			return false;
		if (address_st == null) {
			if (other.address_st != null)
				return false;
		} else if (!address_st.equals(other.address_st))
			return false;
		if (city == null) {
			if (other.city != null)
				return false;
		} else if (!city.equals(other.city))
			return false;
		if (code != other.code)
			return false;
		if (company == null) {
			if (other.company != null)
				return false;
		} else if (!company.equals(other.company))
			return false;
		if (country == null) {
			if (other.country != null)
				return false;
		} else if (!country.equals(other.country))
			return false;
		if (mail == null) {
			if (other.mail != null)
				return false;
		} else if (!mail.equals(other.mail))
			return false;
		if (name1 == null) {
			if (other.name1 != null)
				return false;
		} else if (!name1.equals(other.name1))
			return false;
		if (name2 == null) {
			if (other.name2 != null)
				return false;
		} else if (!name2.equals(other.name2))
			return false;
		if (name3 == null) {
			if (other.name3 != null)
				return false;
		} else if (!name3.equals(other.name3))
			return false;
		if (name4 == null) {
			if (other.name4 != null)
				return false;
		} else if (!name4.equals(other.name4))
			return false;
		if (phone == null) {
			if (other.phone != null)
				return false;
		} else if (!phone.equals(other.phone))
			return false;
		if (postal_code == null) {
			if (other.postal_code != null)
				return false;
		} else if (!postal_code.equals(other.postal_code))
			return false;
		if (start_date == null) {
			if (other.start_date != null)
				return false;
		} else if (!start_date.equals(other.start_date))
			return false;
		if (state == null) {
			if (other.state != null)
				return false;
		} else if (!state.equals(other.state))
			return false;
		if (tax_id_1 == null) {
			if (other.tax_id_1 != null)
				return false;
		} else if (!tax_id_1.equals(other.tax_id_1))
			return false;
		if (tax_id_2 == null) {
			if (other.tax_id_2 != null)
				return false;
		} else if (!tax_id_2.equals(other.tax_id_2))
			return false;
		if (tax_type_1 == null) {
			if (other.tax_type_1 != null)
				return false;
		} else if (!tax_type_1.equals(other.tax_type_1))
			return false;
		if (tax_type_2 == null) {
			if (other.tax_type_2 != null)
				return false;
		} else if (!tax_type_2.equals(other.tax_type_2))
			return false;
		return true;
	}

	@Override
	public String toString() {
		return "Customer [company=" + company + ", code=" + code + ", name1="
				+ name1 + ", name2=" + name2 + ", name3=" + name3 + ", name4="
				+ name4 + ", address_st=" + address_st + ", address_no="
				+ address_no + ", address_fl=" + address_fl + ", address_ap="
				+ address_ap + ", city=" + city + ", state=" + state
				+ ", country=" + country + ", postal_code=" + postal_code
				+ ", tax_id_1=" + tax_id_1 + ", tax_type_1=" + tax_type_1
				+ ", tax_id_2=" + tax_id_2 + ", tax_type_2=" + tax_type_2
				+ ", start_date=" + start_date + ", phone=" + phone + ", mail="
				+ mail + "]";
	}

}
